package com.yonyou.pmclouds.organization.rmiitf;

import com.yonyou.pmclouds.basecom.exception.BusinessException;
import com.yonyou.pmclouds.organization.entity.OrgAndRoleVO;
import com.yonyou.pmclouds.organization.entity.OrganizationVO;
import com.yonyou.pmclouds.organization.entity.RoleDistributeVO;

import java.util.Set;

/**
 * 组织
 */
public interface OrganizationMaintain {

    OrganizationVO[] insertOrgs(OrganizationVO[] organizationVOS) throws BusinessException;
    OrganizationVO[] updateOrg(OrganizationVO[] organizationVOS, String[] updateFields) throws BusinessException;
    OrganizationVO deleteOrg(OrganizationVO organizationVO) throws BusinessException;
    OrganizationVO[] update4Enable(OrganizationVO[] organizationVOS) throws BusinessException;
    OrganizationVO[] update4Disable(OrganizationVO[] organizationVOS, Set<String> recordRoel) throws BusinessException;
    void update4Distribute(OrgAndRoleVO[] orgRoleVOS) throws BusinessException;
    void update4CancelDistribute(String pkRole) throws BusinessException;

    RoleDistributeVO[] insertRoles(RoleDistributeVO[] roleDistributeVOS) throws BusinessException;
}
